#ifndef TLS_INTEGRATER_H
#define TLS_INTEGRATER_H
#include "uniform_grid.h"
#include "bvh.h"

#include "camera.h"

#include "light.h"
#include "material.h"

#include "geometry.h"
#include "sampler.h"
#include <vector>

namespace tls{
  struct integrater{
    virtual vec3 L(ray& r)const=0;
    virtual void render()=0;
    virtual ~integrater()=0;
  };

  //diffuse
  struct diffuse:public integrater{
    bvh* aggr;
    camera* cam;
    sampler* samp;
    std::vector<light*> lights;
    std::vector<material*> mats;

    ~diffuse();

    vec3 L(ray& r)const;
    void render();

  };//struct diffuse integrater

  struct ambient_occ:public integrater{
    bvh* aggr;
    camera* cam;
    sampler* samp_aa;
    sampler* samp_light;
    std::vector<material*> mats;

    ~ambient_occ();
    vec3 L(ray& r)const;
    void render();
  };//struct ambient_occ integrater

}//namespace tls;

#endif

